@import '../app/variables.scss';

.vxe-table {
  *::-webkit-scrollbar-thumb {
    background-color: #ddd;
    background-clip: padding-box;
    border: 3px solid transparent;
    border-radius: 7px;
  }
  *::-webkit-scrollbar {
    width: 13px;
    height: 14px;
  }
  *::-webkit-scrollbar-track {
    -webkit-box-shadow: inset 0 0 12px #ddd;
  }
  *::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0, 0, 0, 0.2);
  }

  .vxe-tree--btn-wrapper {
    height: 100%;
    & > i {
      color: #595959;
    }
  }

  .vxe-header--row {
    font-weight: bold;
    th {
      position: relative;
      background-image: none;
      &:before {
        content: '';
        opacity: 0.08;
        left: 0;
        position: absolute;
        top: 0;
        width: 100%;
        height: 100%;
        background: $--color-primary;
      }
    }
  }
  .vxe-tree--btn-wrapper {
    height: 100%;
    padding: 0 4px;
    & > i {
      color: #595959;
    }
  }
  &.size--small {
    .vxe-header--row {
      font-weight: bold;
      th {
        position: relative;
        &:before {
          content: '';
          opacity: 0.08;
          left: 0;
          position: absolute;
          top: 0;
          width: 100%;
          height: 100%;
          background: $--color-primary;
        }
      }
    }
    .vxe-table--body {
      .row--current {
        background: #fff;
        td {
          background: transparent;
          position: relative;
          z-index: 10;
          &:before {
            content: '';
            opacity: 0.1;
            left: 0;
            position: absolute;
            top: 0;
            width: 100%;
            height: 100%;
            z-index: -1;
            background: $--color-primary;
          }
        }
      }
    }
  }

  &.size--mini {
    .vxe-header--row {
      height: 38px;
      font-weight: bold;
      th {
        position: relative;
        &:before {
          content: '';
          opacity: 0.08;
          left: 0;
          position: absolute;
          top: 0;
          width: 100%;
          height: 100%;
          background: $--color-primary;
        }
      }
    }
    .vxe-table--body {
      .row--current {
        background: #fff;
        td {
          background: transparent;
          position: relative;
          z-index: 10;
          &:before {
            content: '';
            opacity: 0.1;
            left: 0;
            position: absolute;
            top: 0;
            width: 100%;
            height: 100%;
            z-index: -1;
            background: $--color-primary;
          }
        }
      }
    }
  }
}

.vxe-popper {
  padding: 0;
  .vxe-list-item {
    font-size: 14px;
    padding: 0 20px;
    position: relative;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #606266;
    height: 34px;
    line-height: 34px;
    box-sizing: border-box;
    cursor: pointer;
    &.vxe-list-item--active {
      color: $--color-primary;
      font-weight: 700;
    }
    &:hover {
      background-color: #f5f7fa;
    }
  }
}
